package com.htjc.uep.center.commons.utils;

import java.io.Closeable;
import java.io.IOException;

public class IOUtil {

	/**
	 * 关闭一个或多个流对象
	 * @param closeables
	 * @throws IOException
	 */
	public static void close(Closeable... closeables) throws IOException {
		if (closeables != null) {
			for (Closeable closeable : closeables) {
				closeable.close();
			}
		}
 	}
	
	public static void closeQuietly(Closeable... closeables) {
		try {
			close(closeables);
		} catch (Exception e) {
			//do nothing
		}
	}
}
